package com.example.demo.mapper;


import com.example.demo.model.OrderInfo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;


@Mapper
public interface OrderMapper {


    int createOrder(OrderInfo orderInfo);

    List<OrderInfo> getBoughtOrders(Integer userId, String status);
    List<OrderInfo> getSoldOrders(@Param("userId") Integer userId, @Param("status") String status);
    OrderInfo getOrderByOrderNo(String orderNo);
    int updateOrderStatus(OrderInfo order);
    int updateOrderDelete(OrderInfo order);
}
